package com.liuzhilong.infrastructure.basic.decorator.chain.impl;

import com.liuzhilong.infrastructure.basic.decorator.chain.Message;
import com.liuzhilong.infrastructure.basic.decorator.chain.MessageHandler;
import com.liuzhilong.infrastructure.basic.decorator.chain.MessageHandlerChain;

/**
 *
 */
public class DefaultReportEmitter implements MessageHandler {
    static {
        new DefaultReportEmitter().init();
    }
    //初始化一个
    private void init(){
        MessageHandlerChain.append(this);
    }


    @Override
    public int getOrder() {
        return Integer.MAX_VALUE;
    }

    @Override
    public void exec(Message message, MessageHandlerChain messageHandlerChain) {
        System.out.println("没有找到执行器，由DefaultReportEmitter默认执行器执行");
    }
}
